@extends('home.layoutedDetail')
@section('content')
<style type="text/css" media="screen">
    .inp1
    {
        color:#CA151E;
    }
</style>

<div class="hr-10"></div>
<div class="g">
    <!--面包屑 -->
<div class="breadcrumb-area"><a href="/" title="首页">首页</a>&nbsp;&nbsp;\&nbsp;&nbsp;<em id="personCenter"><a href="/member/" title="我的商城">我的商城</a></em><em id="pathPoint">&nbsp;&nbsp;\&nbsp;&nbsp;</em><span id="pathTitle"></span></div>
</div>
<div class="hr-10"></div>

<div class="g">
    <div class="fr u-4-5"><!-- 20141212-栏目-start -->
<div class="section-header">
    <div class="fl">
        <h2><span>{{ $info }}</span></h2>
    </div>
    <div class="fr">
        <div class="ec-tab" id="ec-tab">
            <ul>
                <li><a href="javascript:;" onclick="ec.member.orderList.seltime(this,0);"><span>最近三月内订单<em id="count-seltime-0"></em></span></a></li>
                <li><a href="javascript:;" onclick="ec.member.orderList.seltime(this,1);"><span>三个月前订单<em id="count-seltime-1"></em></span></a></li>
            </ul>
            <div class="ec-tab-arrow" style="width: 122px; left: 0px;"></div>
        </div>
    </div>
</div>
<!-- 20141212-栏目-end -->
<!-- 20141222-我的订单-订单类别-start -->
<div class="myOrder-cate" id="myOrder-cate">
    <ul>
        <li class="current"><a href="{{ asset('/home/indent/index') }}" onclick="ec.member.orderList.check(this,'all');"><span>全部<em></em></span></a></li>
        <li><h3 class = "h">
            <a href="{{ asset('/home/indent/is_pay') }}" onclick="ec.member.orderList.check(this,'unpaid');">
                <span>待支付<em id="count-seltime-2"  data-num="1"></em></span>
            </a>
        </h3></li>
        <li><h3 class = "h"><a href="{{ asset('/home/indent/is_send') }}" onclick="ec.member.orderList.check(this,'unpaid');"><span>待发货<em id="count-seltime-2"  data-num="1"></em></span></a></h3></li>
        <li><h3 class = "h"><a href="{{ asset('/home/indent/is_receive') }}" onclick="ec.member.orderList.check(this,'send');"><span>待收货<em id="count-seltime-3" class="hide" data-num="0">0</em></span></a></h3></li>
        <li><h3 class = "h"><a href="{{ asset('/home/indent/is_comment') }}" onclick="ec.member.orderList.check(this,'nocomment');"><span>待评价<em id="nocommentNum"></em></span></a></h3></li>
    </ul>
</div>
<!-- 20141222-我的订单-订单类别-end -->
<!-- 20141222-我的订单-列表-start -->
<div class="myOrder-record" id="myOrders-list-content">
    <!-- 20141222-我的订单-列表-订单合并-start -->
    <!-- 20141222-我的订单-列表-订单合并-end -->
    <div class="list-group-title">
        <table border="0" cellpadding="0" cellspacing="0">
            <thead>
                <tr>
                    <th class="col-pro">商品</th>
                    <th class="col-price">单价/元</th>
                    <th class="col-quty">数量</th>
                    <th class="col-pay">实付款/元</th>
                    <th class="col-operate">订单状态及操作</th>
                </tr>
            </thead>
        </table>
    </div>
    @foreach($data as $k => $v)
    <div class="list-group" id="list-group">
        <div class="list-group-item">
            <div class="o-info">
                <div class="col-info">
                        <input type="checkbox" class="checkbox" name="payCheck" value="11361603481" paymentStatus="2"/>
                    <span class="o-date">{{ $v -> time }}</span>
                    <span class="o-no">订单号：<a href="/member/order-11361603481" title="11361603481">{{ $v -> order_number }}</a></span>
                    <!--
                        ie6下鼠标悬停追加ClassName： hover
                        示例：[ o-logistics hover ]
                    -->
                </div>
                <div class="col-state">
                    审核通过&nbsp;|&nbsp;{{ $info }}
                </div>
            </div>
            <div class="o-pro">
                <table border="0" cellpadding="0" cellspacing="0">
                    <tbody>
                        <!-- 组合套餐列表 -->
                        <!-- 普通商品列表 -->
                        <tr>
                            <td class="col-pro-img">
                                <p class="p-img">
                                    <a title="{{ $v -> goodsname}} {{ $v -> rom }} {{ $v -> system}}（{{ $v -> color }}）" href="/product/3419.html#8559" target="_blank">
                                        <img alt="{{ $v -> goodsname}} {{ $v -> rom }} {{ $v -> system}}（{{ $v -> color }}）" src="{{ asset('/uploads/goodspic/') }}/{{ $v->goodspic }}"/>
                                    </a>
                                </p>
                            </td>
                            <td class="col-pro-info">
                                <p class="p-name">

                                    <a title="{{ $v -> goodsname}} {{ $v -> rom }} {{ $v -> system}}（{{ $v -> color }}）" target="_blank" href="/product/3419.html#8559">{{ $v -> goodsname}} {{ $v -> rom }} {{ $v -> system}}（{{ $v -> color }}）</a>
                                </p>
                            </td>
                            <td class="col-price"><em>&yen;</em><span>
                                {{$v -> price}}
                            </span></td>
                            <td class="col-quty">{{ $v -> number }}</td>
                            <td rowspan="2" class="col-pay">
                                <p><em>&yen;</em><span>
                                                {{$v -> price}}

                                </span></p>
                            </td>
                            <td rowspan="2" class="col-operate">
                            @if($v -> is_pay == 0)
                                <p class="p-button"> <a class="button-operate-pay" href="{{ asset('/home/indent/pay') }}/{{ $v -> id }}" target="_blank">
                                <span>立即支付</span></a>
                                </p>
                                <p class="p-link"><a href="{{ asset('/home/indent/edit') }}/{{ $v -> id }}">修改订单</a></p>
                            @endif
                            @if($v -> is_send == 0)
                                <p class="p-link">
                                <input type="hidden" name="id" value = "{{ $v -> id }}">
                                <input type = "submit" value = "取消订单" class = "inp" style = "border:0;background:#FFF;" >
                                </p>
                            @endif
                                <p class="p-link"><a href="{{ asset('/home/indent/detail') }}/{{ $v -> id }}">订单详情</a></p>
                            </td>
                        </tr>
                        <!-- 普通商品列表 end -->
                    </tbody>
                </table>
            </div>
        </div>
    </div>
    @endforeach
    <!-- 20141222-我的订单-列表-订单合并-start -->
    <div class="myOrder-control " id="myOrder-control-bottom">
        <label class="inputbox" id="bottomCheckBoxDiv" name="bottomCheckBoxDiv">
            <!-- 20140819-我的订单-合并付款-start -->
                <input type="checkbox" class="checkbox" id="bottomCheckAllBox" name="bottomCheckAllBox" /><span>全选</span>
            <!-- 20140819-我的订单-合并付款-end -->
        </label>
        <a href="javascript:;" class="button-operate-merge-pay" id="bottomButton" onclick="ec.member.orderList.mergePay();"><span>合并支付</span></a>
    </div>
    <!-- 20141222-我的订单-列表-订单合并-end -->
    <div class="list-group-page">
        <div class="pager" id="list-pager"></div>
    </div>
</div>
<!-- 20141222-我的订单-列表-end -->
<input type="hidden" id="colid" value="0"/>
<input type="hidden" id="checkid" value="all"/>
<form action="#" method="get" id="gotoUrl"></form>
<textarea id="delAlert-tpl" class="hide">
    <div class="box-tips-area">
        <p>1：取消订单将作退款处理，一旦取消，不能恢复。</p>
        <p>2：取消日起5个工作日内退款完成，是否确定操作。</p>
    </div><!-- 20140722-退换货-延保tips-end -->
    <div class="box-button">
        <a class="box-ok" href="javascript:;"><span>确定</span></a>
        <a class="box-cancel" href="javascript:;"><span>取消</span></a>
    </div>
</textarea>

<!-- 物流信息模板 -->
<textarea id="interface-tpl" class="hide">
    <!--#macro interface data-->
        <table cellspacing="0" cellpadding="0" border="0">
            <thead>
                <tr>
                    <th class="col-log-date">处理时间</th>
                    <th class="col-log-info">处理信息</th>
                </tr>
            </thead>
            <tbody>
                <!--#list data as lst-->
                    <tr>
                        <td class="col-log-date">{#new Date(parseInt(lst.logTime)).format("yyyy-MM-dd HH:mm:ss")}</td>
                        <td class="col-log-info">{#lst.logDescription}</td>
                    </tr>
                <!--/#list-->
            </tbody>
        </table>
    <!--/#macro-->
</textarea>

<textarea id="exchange-timeout" class="hide">
    <div class="box-prompt-error-area">
        <div class="h">
            <i></i>
        </div>
        <div class="b">
            <p>对不起，您已经超过规定的退换货有效期，目前不能进行退换货操作！</p><br/>
            <p>温馨提示：如果您是在网店更换过机器或者在商城换过机器，请您凭网店或者商品提供的检测单联系商城客服，在后台给你下换机申请单。</p>
        </div>
    </div>
    <div class="box-custom-button">
        <a class="box-ok box-button-style-1" href="javascript:;"><span>确定</span></a>
    </div>
</textarea>

<textarea id="exchange-agreement" class="hide">
    <!-- 20140828-对话框-协议-退换货办理协议-start -->
    <div class="box-agreement-area">
        <p><b>尊敬的用户：</b></p>
        <p style="text-indent:2em;">您可选择以下方式进行退换货</p>
        <p style="text-indent:2em;"><b>一、寄回商城仓库进行检测退换货</b></p>
        <ul>
            <li style="text-indent:2em;">您好，寄回商品检测前，请您仔细阅读以下条款。</li>
            <li style="text-indent:2em;">1、寄回检测需要您先自行垫付寄回运费，待检测符合退换条件后，商城会返还您的运费。</li>
            <li style="text-indent:2em;">2、请确保寄回商品无人为损坏，否则无法办理退换货。人为损坏包括但不限于：未经授权的维修、外力造成的碰撞破损、进液以及外观刮花划伤、掉漆等。</li>
            <li style="text-indent:2em;">3、退换货申请审核通过仅表示华为商城受理您的退换货申请，但不代表同意您的退换货，您可寄回商城进行检测，具体判断有赖于商品是否有质量问题的检测结果以及其他退换货条件的满足。</li>
            <li style="text-indent:2em;">4、寄回检测换货，请确保将商品主机、完整标配、完整原厂包装一次性寄回，如缺少标配配件等将无法更换。</li>
            <li style="text-indent:2em;">5、寄回检测退货，请确保将商品主机、完整标配、完整原厂包装、发票原件、赠品一次性寄回。</li>
            <li style="text-indent:2em;">6、寄回检测后，不符合退换货规定的商品将原路到付寄回，运费将由您承担。</li>
        </ul>
        <p style="text-indent:2em;"><b>二、当地售后服务网点检测，并换货</b></p>
        <ul>
            <li style="text-indent:2em;">您好，网点检测故障属实后，您可以选择直接在售后服务网点进行换机服务。</li>
            <li style="text-indent:2em;">1、前往售后服务网点前请您拨打网点电话咨询是否可受理。</li>
            <li style="text-indent:2em;">2、请您将发票、故障商品携带齐全前往售后服务网点进行检测换货。</li>
        </ul>
        <p style="text-indent:2em;"><b>三、当地售后服务网点开具检测报告，寄回商城退换货</b></p>
        <ul>
            <li style="text-indent:2em;">您好，您可直接到当地就近华为售后服务网点进行检测，开具检测报告后寄回华为商城仓库进行退换货。</li>
            <li style="text-indent:2em;">1、前往售后服务网点前请您拨打网点电话咨询是否可受理。</li>
            <li style="text-indent:2em;">2、请您将发票、故障商品携带齐全前往售后服务网点进行检测换货。</li>
        </ul>
    </div><!-- 20140828-对话框-协议-退换货办理协议-end -->
</textarea>
<textarea id="box-confirm" class="hide">
<!-- 20140722-退换货-延保tips-start -->
    <div class="box-tips-area">
        <p>请您收到货后，再确认收货。</p>
    </div><!-- 20140722-退换货-延保tips-end -->
    <div class="box-button">
        <a class="box-ok" href="javascript:;"><span>确定</span></a>
        <a class="box-cancel" href="javascript:;"><span>取消</span></a>
    </div>
</textarea>
<textarea id="box-pj" class="hide">
<!-- 20140722-退换货-延保tips-start -->
<div class="box-tips-area">
    <p>此次购物是否让您满意？给个评价吧！</p>
</div>
<div class="box-custom-button">
    <a class="box-cancel box-button-style-2" href="/member/prdRemarkView.html" target="_blank"><span>去评价</span></a>
    <a class="box-cancel box-button-style-1" href="javascript:;"><span>关闭</span></a>
</div>
<!-- 20140722-退换货-延保tips-end -->
</textarea>
<script src="js/orderlist.min.js"></script>
<script src="js/add.min.js"></script>
<script>
ec.load("ec.pager");
</script></div>
    <div class="fl u-1-5">


<!--左边菜单 -->
<div class="mc-menu-area">
    <div class="h"><a href="/member?t=1480337035418" class="button-go-mc" title="我的商城"><span>我的商城</span></a></div>
    <div class="b">
        <ul>
            <li>
                <h3>
                    <span>订单中心</span>
                </h3>
                <ol>
                    <li id="li-order"><a href="/member/order?t=1480337035418" title="我的订单"><span>我的订单<em>0</em></span></a></li>
                    <li id="li-exchange"><a href="/member/exchange?t=1480337035418" title="我的退换货"><span>我的退换货</span></a></li>
                    <li id="li-groupBuyRecord"><a href="/member/groupBuyRecord?t=1480337035418" title="我的团购"><span>我的团购</span></a></li>
                    <li id="li-recover"><a href="/member/recycle/index?t=1480337035418" title="我的回收单"><span>我的回收单</span></a></li>
                </ol>
            </li>
            <li>
                <h3>
                    <span>个人中心</span>
                </h3>
                <ol>
                    <li id="li-myAppointment"><a href="/member/myAppointment?t=1480337035418" title="我的预约"><span>我的预约</span></a></li>
                    <li id="li-notification"><a href="/member/notification?t=1480337035418" title="到货通知"><span>到货通知</span></a></li>
                    <li id="li-point"><a href="/member/point?t=1480337035418" title="等级与特权"><span>等级与特权</span></a></li>
                    <li id="li-newpoint"><a href="/member/newpoint?t=1480337035418" title="我的积分"><span>我的积分</span></a></li>
                    <li id="li-zhima"><a href="/member/zm?t=1480337035418" title="芝麻信用"><span>芝麻信用</span></a></li>
                    <li id="li-authentication"><a href="/authmember/accesstoken?t=1480337035418" title="实名认证"><span>实名认证</span></a></li>
                    <li id="li-balance"><a href="/member/balance?t=1480337035418" title="代金券"><span>代金券</span></a></li>
                    <li id="li-petal"><a href="/member/petal?t=1480337035418" title="我的花瓣"><span>我的花瓣</span></a></li>
                    <li id="li-coupon"><a href="/member/coupon?t=1480337035418" title="我的优惠劵"><span>我的优惠劵</span></a></li>
                    <li id="li-enterprise" class="hide"></li>
                    <li id="li-myAddress"><a href="{{ asset('/home/address/index') }}" title="收货地址管理"><span>收货地址管理</span></a></li>
                    <!--
                    <li id="li-zp"><a href="/member/invoiceQualifications/view?t=1480337035418" title="专票资质"><span>专票资质</span></a></li>
                    -->
                </ol>
            </li>
            <li>
                <h3>
                    <span>社区中心</span>
                </h3>
                <ol>
                    <li id="li-prdRemark"><a href="/member/prdRemarkView?t=1480337035418" title="商品评价"><span>商品评价</span></a></li>
                    <li id="li-msg"><a href="/member/msg?t=1480337035418" title="站内信"><span>站内信</span></a></li>
                </ol>
            </li>
        </ul>
    </div>
    <div class="f"></div>
</div>
    </div>
</div>
<div class="hr-80"></div>
<script type="text/javascript">
     window.onload = function()
        {
            $.ajaxSetup({
                headers: {
                    'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                }
            });

            $('.h').on('click',function(){
                // //获取当前对象
                // var li = $(this).parent();
                // li.attr('class','current');
                $('.h').css('background','red');


        }

</script>
<script type="text/javascript">
    $(".inp").hover(
  function () {

    $(this).addClass("inp1");
  },
  function () {
    $(this).removeClass("inp1");
  }


);
</script>
<script type="text/javascript">

$('.inp').on('click',function(){
    var id = $(this).prev().val();
   if(confirm("您确定要取消订单吗？"))
    {

        location.href="{{ asset('/home/indent/cancel/') }}/ "+id
;
    }

})

    // function firm()
    // {
    // var id = $(this).prev().val();
    // if(confirm("您确定要取消订单吗？")
    // {

    //     location.href="{{ asset('/home/indent/cancel') }}/id";
    // }

</script>
@endsection('content')